/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package structures.table.symboltable;

/**
 *
 * @author Vlad
 */
public class ItemInfo implements Cloneable{

    protected String name;

    public ItemInfo(String name) {
        this.name = name;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    @Override
    public boolean equals(Object obj) {
        if (obj == null) {
            return false;
        }
        if (getClass() != obj.getClass()) {
            return false;
        }
        final ItemInfo other = (ItemInfo) obj;
        
        if (!name.equals(other.name)) {
        	return false;
        }
        
        return true;
    }
    
    

    @Override
	public String toString() {
		return name;
	}

	@Override
    public int hashCode() {
        int hash = 3;
        hash = 59 * hash + (this.name != null ? this.name.hashCode() : 0);
        return hash;
    }

	@Override
	public Object clone() {
		return new ItemInfo(name);
	}
    
}
